package com.ruoyi.web.controller.app;

import com.alibaba.fastjson.JSONObject;
import com.ruoyi.common.config.RuoYiConfig;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.utils.file.FileUploadUtils;
import com.ruoyi.system.domain.SysCfca;
import com.ruoyi.system.domain.node;
import com.ruoyi.system.service.ISysCfcaService;
import com.ruoyi.system.service.ISysUserService;
import com.ruoyi.web.controller.tool.myscrew;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import static com.ruoyi.common.core.domain.AjaxResult.error;
import static com.ruoyi.common.core.domain.AjaxResult.success;


@RestController
@RequestMapping("/cms/notice/")
public class testCTMController {
    @Autowired
    private ISysUserService userService;
    @Autowired
    private ISysCfcaService sysCfcaService;

    @GetMapping ("list")
    Object list( ) {
       String aa="{\n" +
               "    \"data\": {\n" +
               "        \"msg\": \"提交成功\",\n" +
               "        \"code\": 0,\n" +
               "        \"requestdata\": [\n" +
               "            {\n" +
               "                \"createBy\": null,\n" +
               "                \"createTime\": null,\n" +
               "                \"updateBy\": null,\n" +
               "                \"updateTime\": null,\n" +
               "                \"remark\": null,\n" +
               "                \"id\": \"1\",\n" +
               "                \"classname\": \"家常菜\",\n" +
               "                \"classtype\": \"001\",\n" +
               "                \"creatertime\": \"1\",\n" +
               "                \"flagstate\": \"1\"\n" +
               "            }\n" +

               "        ]\n" +
               "    }\n" +
               "}";
       System.out.println(">>>>>>>>>"+aa);
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("getPostPageList")
    Object getPostPageList( ) {
        String aa="{\n" +
                "    \"data\": {\n" +
                "        \"msg\": \"提交成功\",\n" +
                "        \"code\": 0,\n" +
                "        \"requestdata\": [\n" +
                "            {\n" +
                "                \"createBy\": null,\n" +
                "                \"createTime\": null,\n" +
                "                \"updateBy\": null,\n" +
                "                \"updateTime\": null,\n" +
                "                \"remark\": null,\n" +
                "                \"id\": \"1\",\n" +
                "                \"classname\": \"家常菜\",\n" +
                "                \"classtype\": \"001\",\n" +
                "                \"creatertime\": \"1\",\n" +
                "                \"flagstate\": \"1\"\n" +
                "            }\n" +
                "        ]\n" +
                "    }\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("memberLogin")
    Object memberLogin( ) {
        String aa="{\n" +
                "    \"code\": 200,\n" +
                "    \"data\": {\n" +
                "        \"code\": 1,\n" +
                "        \"data\": {\n" +
                "            \"jobId\": 14399\n" +
                "        },\n" +
                "        \"success\": true,\n" +
                "        \"message\": \"同步成功\"\n" +
                "    },\n" +
                "    \"success\": true\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("getIndustryList")
    Object getIndustryList( ) {
        String aa="{\n" +
                "    \"data\": {\n" +
                "        \"msg\": \"提交成功\",\n" +
                "        \"code\": 0,\n" +
                "        \"requestdata\": [\n" +
                "            {\n" +
                "                \"createBy\": null,\n" +
                "                \"createTime\": null,\n" +
                "                \"updateBy\": null,\n" +
                "                \"updateTime\": null,\n" +
                "                \"remark\": null,\n" +
                "                \"id\": \"1\",\n" +
                "                \"classname\": \"家常菜\",\n" +
                "                \"classtype\": \"001\",\n" +
                "                \"creatertime\": \"1\",\n" +
                "                \"flagstate\": \"1\"\n" +
                "            }\n" +
                "        ]\n" +
                "    }\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("jobSync")
    Object jobSync( ) {
        String aa="{\n" +
                "    \"code\": 200,\n" +
                "    \"data\": {\n" +
                "        \"code\": 1,\n" +
                "        \"data\": {\n" +
                "            \"jobId\": 14399\n" +
                "        },\n" +
                "        \"success\": true,\n" +
                "        \"message\": \"同步成功\"\n" +
                "    },\n" +
                "    \"success\": true\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("jobOffLine")
    Object jobOffLine( ) {
        String aa="{\n" +
                "    \"code\": 200,\n" +
                "    \"data\": {\n" +
                "        \"code\": 1,\n" +
                "        \"data\": {\"jobId\": 316839},\n" +
                "        \"success\": true,\n" +
                "        \"message\": \"下架成功\"\n" +
                "    },\n" +
                "    \"success\": true\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("syncJdBack")
    Object syncJdBack( ) {
        String aa="{\n" +
                "    \"message\": \"成功\",\n" +
                "    \"code\": \"1\",\n" +
                "    \"success\": true\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("jobNoticeSync")
    Object jobNoticeSync( ) {
        String aa="{\n" +
                "    \"message\": \"成功\",\n" +
                "    \"code\": \"1\",\n" +
                "    \"success\": true\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("pushDailyData")
    Object pushDailyData( ) {
        String aa="{\n" +
                "    \"message\": \"成功\",\n" +
                "    \"code\": \"1\",\n" +
                "    \"success\": true\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @PostMapping ("pushApplyData")
    Object pushApplyData( ) {
        String aa="{\n" +
                "    \"message\": \"成功\",\n" +
                "    \"code\": \"1\",\n" +
                "    \"success\": true\n" +
                "}";
        Object bb = JSONObject.parse(aa);
        return bb;
    }
    @GetMapping ("myscrew")
    void myscrew( ) {
        myscrew.screw();
    }

}
